package com.rockwell.sniffyhunter.utils;

import com.rockwell.sniffyhunter.model.SnifferObject;

public enum SnifferState implements IStateMachine {
	START {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Start actions");
			return ((SnifferObject)stateObject).start();
		}
	},
	ROTATE_FOR_FIRST_SCAN {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Rotate Left for First Scan actions");
			return ((SnifferObject)stateObject).RotateForFirstScan();
		}
	},
	SCAN {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Scan actions");
			return ((SnifferObject)stateObject).Scan();
		}
	},
	INDEX_ROTATE {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Index rotate actions");
			return ((SnifferObject)stateObject).IndexRotate();
		}
	},
	MAP_DISCOVERED_AREA {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Map Discovered Area actions");
			return ((SnifferObject)stateObject).MapDiscoveredArea();
		}
	}, 
	ROTATE_BACK{
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Rotate back actions");
			return ((SnifferObject)stateObject).RotateBack();
		}
	},
	DONE {
		@Override
		public
		IStateMachine doAction(IStateObject stateObject) {
			System.out.println("SnifferState> Perform Done actions");
			return START;
		}
	},
}
